import service from '@/utils/request'
// export const login = (mobile: string) => {
// 	return service.post('/sys/auth/login')
// }
// export const login = (data: any) => {
// 	return service.post('/sys/auth/login', data)
// }


export const login = (dataForm: any) => {
	return service({
		url: '/sys/auth/login',
		method: 'post',
		data: dataForm
	})
}
export const password = (dataForm: any) => {
	return service({
		url: '/sys/user/password',
		method: 'post',
		data: dataForm
	})
}
export const info = (dataForm: any) => {
	return service({
		// url: '/sys/user/info',
		url: '/sys/user/switchorg',
		method: 'get',
		params: dataForm
	})
}
export const orgList = (dataForm: any) => {
	return service({
		url: '/sys/user/org',
		method: 'get',
		params: dataForm
	})
}
export const platformList = (dataForm: any) => {
	return service({
		url: '/sys/platform/list/org',
		method: 'get',
		params: dataForm
	})
}
export const logout = (dataForm: any) => {
	return service({
		url: '/sys/auth/logout',
		method: 'post',
		data: dataForm
	})
}
export const ScheduleGroupList = (dataForm: any) => {
	return service({
		url: '/data-development/ScheduleGroup/list',
		method: 'get',
		params: dataForm
	})
}
export const estimatBoolean = (id: any) => {
	return service({
		url: '/data-development/schedule/estimate/' + id,
		method: 'get',
		// params: id
	})
}
export const odsQuery = (type: string) => {
	if (type) {

		return service.get(`/data-integrate/ods/query?type=${type}`)
	} else {
		return service.get(`/data-integrate/ods/query`)
	}
}
export const platformPlatformList = (dataForm: any) => {
	return service({
		url: '/sys/platform/platformList',
		method: 'get',
		params: dataForm
	})
}
export const layerList = (dataForm: any) => {
	return service({
		url: '/data-integrate/layer/list',
		method: 'get',
		params: dataForm
	})
}
// export const useCaptchaApi = () => {
// 	return service.get('/sys/auth/captcha')
// }

// export const useSendCodeApi = (mobile: string) => {
// 	return service.post('/sys/auth/send/code?mobile=' + mobile)
// }

// export const useAccountLoginApi = (data: any) => {
// 	return service.post('/sys/auth/login', data)
// }

// export const useMobileLoginApi = (data: any) => {
// 	return service.post('/sys/auth/mobile', data)
// }

// export const useLogoutApi = () => {
// 	return service.post('/sys/auth/logout')
// }
